import request from '../utils/request'

export default {
    //查询文件列表
    findFileListApi(params){
        return request({
            method:'get',
            url:'/warehouse/findfilelist',
            params
        })

    },
    //新建文件夹
    newFolderNameApi(data){
        return request({
            method:'post',
            url:'/warehouse/newfolder',
            data
        })
    },
    downloadFileApi(params){
        return request({
            method:'get',
            url:'/file/download',
            params,
            responseType: 'blob'
        })
    },
    //文件/文件夹重命名
     renameApi(data){
        return request({
            method:'put',
            url:'/warehouse/rename',
            data
        })
    },
    //删除文件
    deleteFileApi(data){
        return request({
            method: 'delete',
            url:'/recycle/delete',
            data
        })
    },
    //查看上传下载权限
    getTrans(){
        return request({
            method:'get',
            url:'/user/gettrans'
        })
    }


}